package com.clstu.tankgame5;

public class Bom {
    private int x;
    private int y;
    private int life=9;
    private boolean isLive=true;

    public int getX() {
        return x;
    }

    public int getY() {
        return y;
    }

    public void setLive(boolean live) {
        isLive = live;
    }

    public Bom(int x, int y) {
        this.x = x;
        this.y = y;
    }

    public boolean isLive() {
        return isLive;
    }

    public int getLife() {
        return life;
    }

    public void lifeDown(){
        if (life>0){
            life--;
        }else {
            isLive = false;
        }
    }
}
